
package com.itheima.dao.Repository;

import com.itheima.model.domain.CollectInfo;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import java.util.List;

public interface CollectInfoRepository extends JpaRepository<CollectInfo,Integer> {
    @Query(value = "select  a from CollectInfo a where a.collct_user_tel.user_tel=:user_tel")
    List<CollectInfo> findAllNewsBytel(@Param("user_tel")String user_tel);

    List<CollectInfo> findAll();
}
